package com.chenyaowei.order.request;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;


public class OrderSubmitRequest implements Serializable {

    private static final long serialVersionUID = 1L;

    /** skuId */
    private Long skuId;
    /** 数量 */
    private Integer count;
    // 上面两个字段是空的，就去购物车获取需要购买的商品信息
    /** 收货地址id */
    @NotNull(message = "收货地址不能为空")
    private Long addressId;
    /** 支付类型 */
    @NotNull(message = "支付方式不能为空")
    private Integer payType;
    /** 防重令牌 */
    private String orderToken;
    /** 应付价格 验价 */
    private BigDecimal payPrice;
    /** 使用的优惠劵id */
    private Long couponId;
    /** 订单备注 */
    private String note;

    public Long getSkuId() {
        return skuId;
    }

    public void setSkuId(Long skuId) {
        this.skuId = skuId;
    }

    public Integer getCount() {
        return count;
    }

    public void setCount(Integer count) {
        this.count = count;
    }

    public Long getAddressId() {
        return addressId;
    }

    public void setAddressId(Long addressId) {
        this.addressId = addressId;
    }

    public Integer getPayType() {
        return payType;
    }

    public void setPayType(Integer payType) {
        this.payType = payType;
    }

    public String getOrderToken() {
        return orderToken;
    }

    public void setOrderToken(String orderToken) {
        this.orderToken = orderToken;
    }

    public BigDecimal getPayPrice() {
        return payPrice;
    }

    public void setPayPrice(BigDecimal payPrice) {
        this.payPrice = payPrice;
    }

    public Long getCouponId() {
        return couponId;
    }

    public void setCouponId(Long couponId) {
        this.couponId = couponId;
    }

    public String getNote() {
        return note;
    }

    public void setNote(String note) {
        this.note = note;
    }

    @Override
    public String toString() {
        return "OrderSubmitRequest{" +
                "skuId=" + skuId +
                ", count=" + count +
                ", addressId=" + addressId +
                ", payType=" + payType +
                ", orderToken='" + orderToken + '\'' +
                ", payPrice=" + payPrice +
                ", couponId=" + couponId +
                ", note='" + note + '\'' +
                '}';
    }
}
